import Vue from 'vue'
import Router from 'vue-router'

Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/ermManageWindow',
      name: 'ermManage',
      meta: {
        keepAlive: true, //此组件需要被缓存
      },
      component: () => import("@/apps/erm/AppIndex")
    }, {
      path: '/miniTool',
      name: 'miniTool',
      component: () => import("@/windows/miniTool")
    },
    {
      path: '/scanWorrOperation',
      name: 'scanWorrOperation',
      meta: {
        keepAlive: true, //此组件需要被缓存
      },
      component: () => import("@/apps/scanworr/OperationView")
    },
    {
      path: '/scanJemeterOperation',
      name: 'scanJemeterOperation',
      meta: {
        keepAlive: true, //此组件需要被缓存
      },
      component: () => import("@/apps/jmetterscaner/OperationView")
    },
    {
      path: '/',
      name: 'app',
      component: () => import("@/windows/App"),
      children: [{
        path: '/',
        name: 'Index',
        component: () => import("@/windows/Index"),
        children: [{
          path: '/',
          name: '/',
          component: () => import("@/windows/AworkBench"),
        },
        {
          path: 'reload',
          name: 'reload',
          meta: {
            keepAlive: true, //此组件需要被缓存
          },
          component: () => import("@/windows/Reload")
        },
        {
          path: 'cd',
          name: 'cd',
          meta: {
            keepAlive: true, //此组件需要被缓存
          },
          component: () => import("@/components/cd/Cd")
        },
        {
          path: 'aReport',
          name: 'aReport',
          meta: {
            keepAlive: true, //此组件需要被缓存
          },
          component: () => import("@/windows/AReport")
        },
        {
          path: 'scanWorr',
          name: 'scanWorr',
          meta: {
            keepAlive: true, //此组件需要被缓存
          },
          component: () => import("@/apps/scanworr/AppIndex")
        },
        {
          path: 'jemterScaner',
          name: 'jemterScaner',
          meta: {
            keepAlive: true, //此组件需要被缓存
          },
          component: () => import("@/apps/jmetterscaner/AppIndex")
        },
        {
          path: 'md',
          name: 'md',
          meta: {
            keepAlive: true, //此组件需要被缓存
          },
          component: () => import("@/apps/md/MdIndex.vue")
        },
        {
          path: 'urlToJson',
          name: 'urlToJson',
          meta: {
            keepAlive: true, //此组件需要被缓存
          },
          component: () => import("@/apps/UrlToJson/AppIndex")
        },
        {
          path: 'ermManage',
          name: 'ermManage',
          meta: {
            keepAlive: true, //此组件需要被缓存
          },
          component: () => import("@/apps/erm/AppIndex")
        },
        {
          path: 'encryption',
          name: 'encryption',
          meta: {
            keepAlive: true, //此组件需要被缓存
          },
          component: () => import("@/apps/encryption/AppIndex")
        },
        {
          path: 'setting',
          name: 'setting',
          component: () => import("@/windows/Setting"),
          children: [{
            path: 'theme',
            name: 'theme',
            component: () => import("@/components/setting/Theme"),
          },
          {
            path: 'account',
            name: 'account',
            component: () => import("@/components/setting/Account"),
          },
          {
            path: 'dependence',
            name: 'dependence',
            component: () => import("@/components/setting/Dependence"),
          },
          {
            path: 'about',
            name: 'about',
            component: () => import("@/components/setting/About"),
          }
          ]
        }
        ]
      },]
    },

  ]
})
